<?php

namespace Jb\Navigation;

use Jb\Object,
    Jb\Utils\Comparison\Comparable;

// Acts as a decorator for other Comparable objects, to more clearly speak to the domain of a Navigation system
class Route extends Object implements Comparable {

    protected $oComparable;

    public function __construct(Comparable $comparisonStrategy) {
        $this->oComparable = $comparisonStrategy;
    }

    public function compareTo(Object $comparisonObject) {
        return $this->oComparable->compareTo($comparisonObject);
    }

    public function toString() {
        return $this->oComparable->toString();
    }

}

?>
